<template>
    <div class="GrandSon">
        <h1>孙组件</h1>
        <p>b:{{ b }} c:{{ c }}</p>
        <!-- 调用传过来的祖方法 -->
        <button @click="fun(1)">b加1</button>
    </div>
    </template>
    
    <script lang="ts">
    export default {
    name:'GrandSon'
    }
    </script>
    
    <script setup lang="ts">
import { ref } from 'vue';
    //取参数
    defineProps(['b', 'c','fun'])
    
    </script>
    
    <style lang="css">
    .GrandSon{
        height: 200px;
        width: 500px;
        background-color:blanchedalmond;
    }
    </style>